import Vue from 'vue'
import App from './App.vue'
import VueNativeSock from 'vue-native-websocket'

import router from './router'
import store from './store'
import AntDesignVue from 'ant-design-vue'
import 'ant-design-vue/dist/antd.css'
import './assets/tailwind.css'

Vue.use(VueNativeSock, process.env.VUE_APP_WEBSOCKET || 'ws://localhost:3000', { 
  store, format: 'json', 
  reconnection: true, // (Boolean) whether to reconnect automatically (false)
  reconnectionAttempts: 5, // (Number) number of reconnection attempts before giving up (Infinity),
  reconnectionDelay: 3000,
})
Vue.use(AntDesignVue)

Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App),
}).$mount('#app')
